<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/html">
<head lang="en">
    <meta charset="UTF-8">
    <title>xls2db</title>
</head>
<body>
<h1>choose your file</h1>

<form action="/upload" method="POST" enctype="multipart/form-data">
    <p>
        <select name="model">
            {% for fn, md in mappings.items() %}
                <option value="{{ md }}" {% if request.form["model"] == md %} selected {% endif %} >{{ fn }}</option>
            {% endfor %}
        </select>
        <input type="file" name="file">
        <input type=submit value="upload">
    </p>
    <h1>{{ status }}</h1>
    <pre>{{ errmsg }}</pre>
</form>
</body>
</html>